/* global chrome */
/** 报备简历 */
export const reportResume = (data) => {
    return new Promise((resolve, reject) => {
        // 发送消息给background脚本
        chrome.runtime.sendMessage({
            type: 'REPORT_RESUME',
            data: data
        }, (response) => {
            if (chrome.runtime.lastError) {
                reject(chrome.runtime.lastError);
            } else {
                resolve(response);
            }
        });
    });
}
